// 版权归 瞄你个汪 所有。使用本代码应遵守相关法律法规和Apache 2.0开源许可要求。
package top.geeke.database.seed;

import top.geeke.entity.SysUserRole;
import top.geeke.toolkit.supertable.seed.SuperSeedData;

import java.util.ArrayList;
import java.util.List;

/**
 * <p>
 * 系统用户角色表种子数据
 * </p>
 *
 * @author 瞄你个汪
 * @since 2024/5/26 8:13
 */
public class SysUserRoleSeedData implements SuperSeedData<SysUserRole> {
    @Override
    public List<SysUserRole> getSeedData() {
        return new ArrayList<SysUserRole>(){{
            add(newInstance(1300000000101L, 1300000000111L, 1300000000101L));
            add(newInstance(1300000000102L, 1300000000112L, 1300000000102L));
            add(newInstance(1300000000103L, 1300000000113L, 1300000000103L));
            add(newInstance(1300000000104L, 1300000000114L, 1300000000104L));
            add(newInstance(1300000000105L, 1300000000115L, 1300000000105L));
        }};
    }

    public SysUserRole newInstance(Long id, Long userId, Long roleId) {
        SysUserRole userRole = new SysUserRole();
        userRole.setId(id);
        userRole.setUserId(userId);
        userRole.setRoleId(roleId);
        return userRole;
    }
}
